<style>
    .td-active{
        background-color:LightSkyBlue;
    }
    .td-active:hover{
        background-color:#00A1CB!important;
    }
    .input1{
        line-height:1;
        display:inline!important;
        width:auto!important;
    }
</style>
<div class="container" style="margin:0 0 0 0;padding:0 0 0 0">
    <div class="row page-header-new" style="margin:0 0 0 0">
        <div class="page-title">
            <h4 >业绩分析</h4>
        </div>
    </div>
    <div class="body">
        <div class="row">
            <div class="col-md-1"></div>
            <div class="col-md-10">
                <div class="btn-group">
                    <button class="btn btn-default" style="line-height: 1;width:{{width7}}px;background-color:	#8470FF">统计类型</button>
                    <button class="{{performanceMode==1?'btn btn-info':'btn btn-default'}}" style="line-height: 1;width: {{width7}}px" ng-click="changePerformanceMode(1)">来源分析</button>
                    <button class="{{performanceMode==2?'btn btn-info':'btn btn-default'}}" style="line-height: 1;width: {{width7}}px" ng-click="changePerformanceMode(2)">业绩分析</button>
                </div>
            </div>
        </div>
        <div class="row">
            <div class="col-md-1"></div>
            <div class="col-md-10">
                <div class="btn-group">
                    <button class="btn btn-default" style="line-height: 1;width:{{width7}}px;background-color:	#8470FF">统计限制条件</button>
                    <button class="{{limitMode==1?'btn btn-info':'btn btn-default'}}" style="line-height: 1;width: {{width7}}px" ng-click="changeLimitMode(1)">整体来源分析</button>
                    <button class="{{limitMode==2?'btn btn-info':'btn btn-default'}}" style="line-height: 1;width: {{width7}}px" ng-click="changeLimitMode(2)">R&R分析</button>
                    <button class="{{limitMode==3?'btn btn-info':'btn btn-default'}}" style="line-height: 1;width: {{width7}}px" ng-click="changeLimitMode(3)">员工推荐分析</button>
                    <button class="{{limitMode==4?'btn btn-info':'btn btn-default'}}" style="line-height: 1;width: {{width7}}px" ng-click="changeLimitMode(4)">推广活动分析</button>
                    <button class="{{limitMode==5?'btn btn-info':'btn btn-default'}}" style="line-height: 1;width: {{width7}}px" ng-click="changeLimitMode(5)">市场活动分析</button>
                </div>
            </div>
        </div>
        <br/>
        <div class="row">
            <div class="col-md-1">
            </div>
            <div class="col-md-1">
                <label for="cause" style="font-weight:normal;line-height:1">选择事由</label>
            </div>
            <div class="col-md-2">
                <select id="cause" class="form-control" ng-model="selectCause" ng-options="x.id as x.name for x in causeList" style="line-height:1"></select>
            </div>
            <div class="pull-right" style="padding-right:200px">
                <button class="btn btn-info" style="line-height:1;padding-left:30px;padding-right:30px" ng-click="initChart()">查看</button>
            </div>
        </div>

        <div class="row">
            <div class="col-md-2"></div>
            <div class="col-md-8">
                <div id="chart_pie_1"></div>
                <table class="datatable table table-hover dataTable" ng-show="performanceMode==1&&limitMode==1">
                    <thead>
                        <th>招商机会来源</th>
                        <th>合同金额（万元）</th>
                    </thead>
                    <tbody>
                        <tr ng-repeat="item in originData">
                            <td>{{item.name}}</td>
                            <td>{{item.amount}}</td>
                        </tr>
                    </tbody>
                </table>
                <table class="datatable table table-hover dataTable" ng-show="performanceMode==1&&limitMode==2">
                    <thead>
                    <th>R&R人员</th>
                    <th>合同金额（万元）</th>
                    </thead>
                    <tbody>
                    <tr ng-repeat="item in contactData">
                        <td>{{item.name}}</td>
                        <td>{{item.amount}}</td>
                    </tr>
                    </tbody>
                </table>
                <table class="datatable table table-hover dataTable" ng-show="performanceMode==1&&limitMode==3">
                    <thead>
                    <th>推荐员工</th>
                    <th>合同金额（万元）</th>
                    </thead>
                    <tbody>
                    <tr ng-repeat="item in employeeData">
                        <td>{{item.name}}</td>
                        <td>{{item.amount}}</td>
                    </tr>
                    </tbody>
                </table>
                <table class="datatable table table-hover dataTable" ng-show="performanceMode==1&&limitMode>3">
                    <thead>
                    <th>活动</th>
                    <th>合同金额（万元）</th>
                    </thead>
                    <tbody>
                    <tr ng-repeat="item in eventData">
                        <td>{{item.name}}</td>
                        <td>{{item.amount}}</td>
                    </tr>
                    </tbody>
                </table>
            </div>
        </div>
    </div>
</div>


